/*
 * Chris Baird,, <chris.j.baird@gmail.com> VK2CJB
 */

#ifndef _SATPREDICT_H_
#define _SATPREDICT_H_


typedef struct {
  float x;
  float y;
} float2;


#define MAXSATS (10)

struct SatStatus
{
  char state;			/* 1: valid orbit data, < 1: not okay */
  float elevation;
  float azimuth;
  float range;
  float lastrange;
  float2 daynum;
  float2 lastdaynum;
  float dopplerhz;
};

extern struct SatStatus satstatus[MAXSATS];


struct SatData
{
  char* name;
  int year;
  float refepoch;
  float drag;
  float incl;
  float raan;
  float eccn;
  float argper;
  float meanan;
  float meanmo;
  long orbitnum;
  float uplink;
};

extern const int numsats;
extern const struct SatData satdata[];

void sat_update (void);

#endif
